class Solution:
    def solution(self , harmList , totalHarm ):
        # write code here
        count = 0
        harmList.sort()
        #harmList.reverse()
        # print(harmList)
        for i in harmList[::-1]:
            # print(i)
            while totalHarm - i >= 0:
                count += 1
                totalHarm = totalHarm - i
                # print('totalHarm',totalHarm)
        if totalHarm == 0:
            return count
        else:
            return -1

print(Solution().solution([1,2,5,11],11))
'''
50%
'''